package com.pmcc.core.web;

import com.pmcc.core.entity.Question;
import com.pmcc.core.service.QuestionService;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * Created by spurs on 2018/11/15.
 */
@RestController()
@RequestMapping("api/v1/question")
@Api(value = "QuestionController", description = "密保问题列表")
public class QuestionController {
    @Autowired
    QuestionService questionService;

    /**
     * 查询密保问题
     * @return
     */
    @GetMapping(value = "queryCombo")
    @ResponseBody
    public List<Question> queryCombo() {
        return questionService.queryToCombo();
    }
}
